<%@ page language="java" pageEncoding="UTF-8" %>
<%@ include file="../../baselist.jsp" %><%--            var ele = document.getElementById("factoryName");--%>

<html xmlns="http://www.w3.org/1999/xhtml">
<%--<head>--%>
<%--    &lt;%&ndash;<title></title>&ndash;%&gt;--%>
<%--    &lt;%&ndash;<script type="text/javascript">--%>
<%--        //设置冗余的生产厂家名称--%>
<%--        function setFactoryName(val){--%>
<%--            ele.value = val;--%>
<%--        }--%>
<%--    </script>&ndash;%&gt;--%>
<%--</head>--%>
<body>
<form method="post" action="${pageContext.request.contextPath}/jExtCproduct/insertjExtCproduct">
    <%--<input type="text" name="ext_Cproduct_id" value="${jExt.ext_Cproduct_id}"/>--%>

    <div id="menubar">
        <div id="middleMenubar">
            <div id="innerMenubar">
                <div id="navMenubar">
                    <ul>
                        <li id="save"><a href="#" onclick="formSubmit('insert.action','_self');">确定</a></li>
                        <li id="back"><a href="${ctx}/cargo/contract/list.action">返回</a></li>
                    </ul>
                </div>
            </div>
        </div>
    </div>
    <div class="textbox" id="centerTextbox">

        <div class="textbox-header">
            <div class="textbox-inner-header">
                <div class="textbox-title">
                    新增附件信息
                </div>
            </div>
        </div>
        <div>
            <div>
                <table class="commonTable" cellspacing="1">
                    <tr>
                        <%-- <td class="columnTitle_mustbe">厂家名称：</td>
                         <td class="tableContent">
                             <select name="factoryId" onchange="setFactoryName(this.options[this.selectedIndex].text);">
                                 <option value="">--请选择--</option>
                                 <c:forEach items="${factoryList}" var="f">
                                     <option value="${f.id}">${f.factoryName}</option>
                                 </c:forEach>
                             </select>
                             <input type="hidden" id="factoryName" name="factoryName" value=""/>
                         </td>--%>
                        <td class="columnTitle_mustbe">货号：</td>
                        <td class="tableContent"><input type="text" name="product_no"/></td>
                    </tr>
                    <td class="columnTitle_mustbe">货物照片：</td>
                    <td class="tableContent"><input type="text" name="product_image"/></td>
                    </tr>
                    <tr>
                        <td class="columnTitle_mustbe">数量：</td>
                        <td class="tableContent"><input type="text" name="cnumber"/></td>
                        <td class="columnTitle_mustbe">包装单位：</td>
                        <td class="tableContent"><input type="text" name="packing_unit"/></td>
                    </tr>
                    <tr>
                        <td class="columnTitle_mustbe">单价：</td>
                        <td class="tableContent"><input type="text" name="price"/></td>
                        <td class="columnTitle_mustbe">排序号：</td>
                        <td class="tableContent"><input type="text" name="order_no"/></td>
                    </tr>
                    <tr>
                        <td class="columnTitle_mustbe">货物描述：</td>
                        <td class="tableContent"><textarea name="product_desc" style="height:120px;"></textarea></td>
                        <td class="columnTitle_mustbe">要求：</td>
                        <td class="tableContent"><textarea name="product_request" style="height:120px;"></textarea></td>
                    </tr>
                </table>
            </div>
        </div>
    </div>
</form>
<div class="textbox" id="centerTextbox">
    <div class="textbox-header">
        <div class="textbox-inner-header">
            <div class="textbox-title">
                附件列表
            </div>
        </div>
    </div>

    <div>

        <div class="eXtremeTable">
            <table id="ec_table" class="tableRegion" width="98%">
                <thead>
                <tr>
                    <td class="tableHeader"><input type="checkbox" name="selid" onclick="checkAll('id',this)"></td>
                    <td class="tableHeader">序号</td>
                    <%--<td class="tableHeader">厂家名称</td>--%>
                    <td class="tableHeader">货号</td>
                    <td class="tableHeader">数量</td>
                    <td class="tableHeader">包装单位</td>
                    <td class="tableHeader">单价</td>
                    <td class="tableHeader">总金额</td>
                    <td class="tableHeader">操作</td>
                </tr>
                </thead>
                <tbody class="tableBody">

                <c:forEach items="${jExt}" var="ext" varStatus="status">
                    <tr class="odd" onmouseover="this.className='highlight'" onmouseout="this.className='odd'">
                        <td><input type="checkbox" name="id" value="${ext.ext_Cproduct_id}"/></td>
                        <td>${status.index+1}</td>
                            <%-- <td>${ext.product_name}</td>--%>
                        <td>${ext.product_no}</td>
                        <td>${ext.cnumber}</td>
                        <td>${ext.packing_unit}</td>
                        <td>${ext.price}</td>
                        <td>${ext.amount}</td>
                        <td>
                            <a href="${pageContext.request.contextPath}/jExtCproduct/jExtCproductUpdate?id=${ext.ext_Cproduct_id}">[修改]</a>
                            <a href="${pageContext.request.contextPath}/jExtCproduct/deletejExtCproduct/${ext.ext_Cproduct_id}">[删除]</a>
                        </td>
                    </tr>
                </c:forEach>

                </tbody>
            </table>
        </div>

    </div>
</div>
</body>
</html>

